package com.justdoit.facedemo.base;


public class Results {

    public static <T> Result<T> newSuccess(T data) {
        return new Result<>("200","请求成功",data);
    }

    public static <T> Result<T> newError(String message) {
        return new Result<>("500", message);
    }

    /**
     * 其他错误状态消息描述
     */
    public static <T> Result<T> newFailedResult(String code, String message) {
        return new Result<>(code,message);
    }

}
